﻿<Window
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2006" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
    x:Class="AutoUpdate.Window1"
    Title="AutoUpdate"
	Height="110"
	Width="270"
    Background="Transparent"
	WindowStyle = "None"
	ResizeMode="NoResize"
	WindowState="Normal"
	AllowsTransparency="True"
	Icon="ViewOn.ico"
	WindowStartupLocation="CenterScreen">
	<Grid>

		<!-- Background -->

		<Border x:Name="root" Background="#FF222222" BorderBrush="#F8555555" BorderThickness="1,1,1,1" CornerRadius="6,6,6,6">

			<Grid x:Name="rootGrid">
				<Grid.RowDefinitions>
					<RowDefinition Height="20"/>
					<RowDefinition Height="*" />
				</Grid.RowDefinitions>

				<!-- Background -->
				<Rectangle Grid.Row="0" Grid.RowSpan="2" Fill="#FF222222" RadiusX="6" RadiusY="6" Stroke="#F0555555" StrokeThickness="1"/>
				<Border Grid.Row="0" Background="#FF222222" CornerRadius="6,6,0,0"/>
				<Border Grid.Row="1" CornerRadius="0,0,6,6">
					<Border.Background>
						<LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
							<GradientStop Color="#FF2A2929" Offset="0.005"/>
							<GradientStop Color="#FF0E0E0E" Offset="0.495"/>
							<GradientStop Color="#FF1A1919" Offset="0.524"/>
							<GradientStop Color="#FF2F2F2F" Offset="1"/>
						</LinearGradientBrush>
					</Border.Background>
				</Border>
				<Border Grid.Row="1" BorderThickness="0,1,0,0" BorderBrush="Black"/>
				<Border Grid.RowSpan="2" CornerRadius="6,6,6,6" BorderBrush="#F0333333" BorderThickness="1"/>
				<Border Name="borHeader" Grid.Row="0" Background="#00222222">
					<TextBlock Margin="3,0,0,0" VerticalAlignment="Center" Foreground="White" FontFamily="Tahoma" FontSize="10" Text="ViewOn.tv Automatic update">
						<TextBlock.BitmapEffect>
							<OuterGlowBitmapEffect GlowColor="White" GlowSize="3" Noise="0" Opacity="0.5" />
						</TextBlock.BitmapEffect>
					</TextBlock>
				</Border>

			</Grid>

		</Border>

		<!-- Content -->

		<Grid>
			<Grid.RowDefinitions>
				<RowDefinition Height="23"/>
				<RowDefinition Height="*"/>
				<RowDefinition Height="30"/>
				<RowDefinition Height="30"/>
			</Grid.RowDefinitions>
			<Grid.ColumnDefinitions>
				<ColumnDefinition Width="120"/>
				<ColumnDefinition Width="120"/>
				<ColumnDefinition />
			</Grid.ColumnDefinitions>
			<StackPanel Grid.Column="2" HorizontalAlignment="Right" VerticalAlignment="Center">
				<StackPanel.Resources>
					<Style x:Key="{x:Type Button}" TargetType="{x:Type Button}">
						<Style.BasedOn>
							<Style TargetType="{x:Type Button}">
								<Setter Property="Width" Value="16"/>
								<Setter Property="Height" Value="16"/>
								<Setter Property="Margin" Value="2.5,0,2.5,0"/>
								<Setter Property="Margin" Value="4,0,4,0"/>
								<Setter Property="Padding" Value="2.5,2.5,2.5,2.5"/>
								<Setter Property="VerticalAlignment" Value="Center"/>
								<Setter Property="MinWidth" Value="0"/>
								<Setter Property="Foreground" Value="#FFF2AF12"/>
								<Setter Property="FontFamily" Value="Arial"/>
								<Setter Property="FontSize" Value="12.266666666666666"/>
								<Setter Property="Focusable" Value="False"/>
								<Setter Property="Template">
									<Setter.Value>
										<ControlTemplate TargetType="{x:Type Button}">
											<Grid>
												<Border x:Name="highlight" BorderBrush="#FFffffff" CornerRadius="3,3,3,3" BorderThickness="1,1,1,1" Background="#00ffffff" Opacity="0">
													<Border.BitmapEffect>
														<OuterGlowBitmapEffect GlowColor="White" GlowSize="3" Noise="0" Opacity="0.5" />
													</Border.BitmapEffect>
												</Border>
												<ContentPresenter Margin="{TemplateBinding Padding}" VerticalAlignment="Center" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" />
											</Grid>
											<ControlTemplate.Triggers>
												<EventTrigger RoutedEvent="Mouse.MouseEnter">
													<BeginStoryboard>
														<Storyboard>
															<DoubleAnimation To="0.7" Duration="00:00:00.4000000" Storyboard.TargetName="highlight" Storyboard.TargetProperty="Opacity" />
														</Storyboard>
													</BeginStoryboard>
												</EventTrigger>
												<EventTrigger RoutedEvent="Mouse.MouseLeave">
													<BeginStoryboard>
														<Storyboard>
															<DoubleAnimation To="0" Duration="00:00:00.4000000" Storyboard.TargetName="highlight" Storyboard.TargetProperty="Opacity" />
														</Storyboard>
													</BeginStoryboard>
												</EventTrigger>
											</ControlTemplate.Triggers>
										</ControlTemplate>
									</Setter.Value>
								</Setter>
							</Style>
						</Style.BasedOn>
					</Style>
				</StackPanel.Resources>
				<Button x:Name="close">
					<Viewbox>
						<Canvas Height="10" Width="10">
							<Line Fill="#FFffffff" X2="9" X1="1" Stroke="#FFffffff" StrokeThickness="1.5" Y2="9" Y1="1" />
							<Line Fill="#FFffffff" X2="1" X1="9" Stroke="#FFffffff" StrokeThickness="1.5" Y2="9" Y1="1" />
						</Canvas>
					</Viewbox>
				</Button>
			</StackPanel>

			<Button x:Name="btnCancel" Grid.Row="3" VerticalAlignment="Center" Width="100" IsDefault="True" Content="Cancel" HorizontalAlignment="Center" Style="{DynamicResource Button.TransparentWithEffect}" Height="20" Padding="3,0,0,0"/>
			<Button x:Name="btnProxy" Grid.Row="3" VerticalAlignment="Center" Width="100" Content="Proxy" Grid.Column="1" HorizontalAlignment="Center" Style="{DynamicResource Button.TransparentWithEffect}" Visibility="Hidden"/>
			<TextBlock VerticalAlignment="Top" Height="Auto" Text="ViewOn - Automatic update" TextWrapping="Wrap" x:Name="lblProgress" Grid.Column="0" HorizontalAlignment="Center" Width="Auto" Grid.ColumnSpan="3" Margin="0,13,0,0" Grid.Row="1" Foreground="#FFFFFFFF" FontWeight="Bold"/>
			<TextBlock x:Name="txtHyperlinkViewOn" Visibility="Hidden" Grid.Row="2" Grid.ColumnSpan="3" HorizontalAlignment="Center" Margin="0,13,0,0">
				<Hyperlink x:Name="hlViewOn" TextDecorations="Underline" Foreground="White" NavigateUri="http://www.viewon.tv" RequestNavigate="HandleRequestNavigate">Please download ViewOn.tv from the web site</Hyperlink>
			</TextBlock>
		</Grid>

	</Grid>
</Window>
